package com.evony.common.beans 
{
    import flash.events.*;
    import mx.events.*;
    
    public class TroopConfigBean extends Object
    {
        public function TroopConfigBean(arg1:Object=null)
        {
            super();
            var loc1:*=0;
            _bindingEventDispatcher = new flash.events.EventDispatcher(flash.events.IEventDispatcher(this));
            if (arg1 != null) 
            {
                if (arg1.name != null) 
                {
                    this.name = arg1.name;
                }
                if (arg1.time != null) 
                {
                    this.time = arg1.time;
                }
                if (arg1.troop != null) 
                {
                    this.troop = new com.evony.common.beans.TroopBean(arg1.troop);
                }
            }
            return;
        }

        public function toDebugString(arg1:String=""):String
        {
            var loc1:*=0;
            var loc2:*="";
            loc2 = loc2 + (arg1 + "name = " + this.name + "\n");
            loc2 = loc2 + (arg1 + "time = " + this.time + "\n");
            if (troop == null) 
            {
                loc2 = loc2 + (arg1 + "troop = null\n");
            }
            else 
            {
                loc2 = loc2 + this.troop.toDebugString(arg1 + "troop.");
            }
            return loc2;
        }

        public function copyTo(arg1:com.evony.common.beans.TroopConfigBean):void
        {
            arg1.name = this.name;
            arg1.time = this.time;
            if (troop == null) 
            {
                arg1.troop = null;
            }
            else 
            {
                this.troop.copyTo(arg1.troop);
            }
            return;
        }

        public function toObject():Object
        {
            var loc1:*=new Object();
            loc1.name = this.name;
            loc1.time = this.time;
            loc1.troop = this.troop.toObject();
            return loc1;
        }

        [Bindable]
        public var name:String;

        [Bindable]
        public var time:Number;

        [Bindable]
        public var troop:com.evony.common.beans.TroopBean;
    }
}
